<html>
<head>
<title>order detail</title>
<LINK href="../css/style.css" type=text/css rel=stylesheet>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"></head>

<body>
 
  <table width="96%" border=0 align="center" cellpadding=5 cellspacing=0>
      <tr height="25px">

        <td width="100%"><table border="0" width="100%" cellspacing="0" cellpadding="0">

          <tr>

            <td class="pageHeading">Orders</td>

            <td class="pageHeading" align="right"><img src="../images/pixel_trans.gif" border="0" alt="" width="1" height="40"></td>

            <td align="right">&nbsp;<A href="{$backurl}" target="_self">Back</A>&nbsp;&nbsp;</td>

          </tr>

        </table></td>

      </tr>
    <tr height="5px">
           <td colspan="3"><img src="../images/pixel_black.gif" border="0" alt="" width="100%" height="1"></td>
	</tr>
    
    <tr height="210px">
        <td align="left" valign="top">
        	<table width="100%" border="0" cellspacing="0" cellpadding="2">
	          <tr>
	            <td colspan="3"><img src="images/pixel_black.gif" border="0" alt="" width="100%" height="1"></td>
	          </tr>

          	<tr>
           	<td valign="top">
           		<table width="100%" border="0" cellspacing="0" cellpadding="2">
              		<tr>
                		<td class="main" valign="top"><b>Customer:</b></td>
               			<td class="main">{$arrOrders.customers_name} <br>
               				{$arrOrders.customers_street}<br>
               				{$arrOrders.customers_city} {$arrOrders.customers_state} {$arrOrders.customers_postcode}<br>
               				{$arrOrders.customers_country}
               			</td>
             		</tr>
              		<tr>
               			<td colspan="2"><img src="images/pixel_trans.gif" border="0" alt="" width="1" height="5"></td>
             		</tr>

              		<tr>
               			<td class="main"><b>Telephone Number:</b></td>
               			<td class="main">{$arrOrders.customers_telephone}</td>
             		</tr>
             		<tr>
              			<td class="main"><b>E-Mail Address:</b></td>
              			<td class="main"><a href="mailto:{$arrOrders.customers_email}"><u>{$arrOrders.customers_email}</u></a></td>
            		</tr>
            		
            		<tr height="35px">
              			<td class="main">&nbsp;</td>
              			<td class="main">&nbsp;</td>
            		</tr>
            		<tr>
              			<td class="main"><b>Order Number:</b></td>
              			<td class="main">{$arrOrders.id}</td>
            		</tr>
            		
            		<tr>
              			<td class="main"><b>Payment Method:</b></td>
              			<td class="main"><font style="line-height:20px">{$arrOrders.payment_method}</font></td>
            		</tr>
          		</table>
          	</td>
          <td valign="top">
          	<table width="100%" border="0" cellspacing="0" cellpadding="2">
             	<tr>
               		<td class="main" valign="top"><b>Shipping Address:</b></td>
               		<td class="main">{$arrOrders.delivery_name} <br>
	               		{$arrOrders.delivery_street}<br>
	               		{$arrOrders.delivery_city} {$arrOrders.delivery_state} {$arrOrders.delivery_postcode} <br>
	               		{$arrOrders.delivery_country}
               		</td>
             	</tr>
           </table>
         </td>
         <td valign="top">
         	<table width="100%" border="0" cellspacing="0" cellpadding="2">
             	<tr>
               		<td class="main" valign="top"><b>Billing Address:</b></td>
               		<td class="main">{$arrOrders.billing_name} <br>
	               		{$arrOrders.billing_street}<br> 
	               		{$arrOrders.billing_city} {$arrOrders.billing_state} {$arrOrders.billing_postcode} <br>
	               		{$arrOrders.billing_country}
               		</td>
             	</tr>
           	</table>
          </td>
         </tr>
       </table>
        </td>
	</tr>
	
      <tr>
        <td align="left" valign="top">
  
	   
<table width="100%" cellspacing="1" cellpadding="4">
  <tr bgcolor="#E4E4E4"> 
    <td width="65%" class="pageFrom"><b>Products</b></td>
    <td width="5%" class="pageFrom"><b>Model</b></td>
    <td width="10%" class="pageFrom"><b>Price</b></td>
    <td width="10%" class="pageFrom"><b>Final Price</b></td>
    <td width="5%" class="pageFrom"><b>Quantity</b></td>
    <td width="5%" class="pageFrom"><b>Total</b></td>
  </tr>
  
  {foreach item=data from=$arrDataList}
  <tr bgcolor="#FFFFFF" onMouseOver="this.style.backgroundColor='#E9EDED';" onMouseOut="this.style.backgroundColor='#FFFFFF'"> 
    <td >&nbsp;<font style="font-size:24px">{$data.quantity}&nbsp;X&nbsp;</font>{$data.name}
    	<br><nobr><small>
           {foreach item=attri from = $data.attributes}
            
            <i> - <font style="font-size:11px">{$attri.attribute}</font>: <font style="font-size:14px">{$attri.attributeValue}</font>
            {if $attri.attributeValuePrice > 0}
            	(${$attri.price_prefix}{$attri.attributeValuePrice / 100})
            {/if}
            
            	
            </i><br>
            
        {/foreach}
          </small></nobr>
    </td>
    <td >&nbsp;{$data.model}</td>
    <td>&nbsp;${$data.price / 100}</td>
    <td>&nbsp;${$data.finalPrice / 100}</td>
    <td>&nbsp;{$data.quantity}</td>
     <td>&nbsp;${$data.finalPrice * $data.quantity / 100}</td>
  </tr>
  {/foreach}

  <tr>

        <td align="right" colspan="8">
        &nbsp;
        </td>

      </tr>
      
  {foreach item=data from=$arrAccountList}
		<tr height="20">
	    	<td colspan="5" align="right"><b>{$data.comments}</b>:</td>
	    	<td align="left">&nbsp;${$data.amount / 100|string_format: "%.2f"}</td>
	  	</tr>
  	{/foreach}
</table>


<!--
<table width="100%" cellspacing="1" cellpadding="4">
  <tr bgcolor="#E4E4E4"> 
    <td width="5%" class="pageFrom"><b>Amount</b></td>
    <td width="10%" class="pageFrom"><b>Amount Class</b></td>
    <td width="85%" class="pageFrom"><b>Comments</b></td>
   </tr>
  
  {foreach item=data from=$arrAccountList}
  <tr bgcolor="#FFFFFF" onMouseOver="this.style.backgroundColor='#E9EDED';" onMouseOut="this.style.backgroundColor='#FFFFFF'"> 
    <td>&nbsp;${$data.amount / 100}</td>
    <td>&nbsp;{$data.classes}</td>
    <td>&nbsp;{$data.comments|nl2br}</td>
  </tr>
  {/foreach}
</table>
-->

<br></br>
<table width="100%" cellspacing="1" cellpadding="4">
  <tr bgcolor="#E4E4E4"> 
    <td width="15%" class="pageFrom"><b>Date Added</b></td>
    <td width="15%" class="pageFrom"><b>Customer Notified</b></td>
    <td width="10%" class="pageFrom"><b>Status</b></td>
    <td width="60%" class="pageFrom"><b>Comments</b></td>
   </tr>
  
  {foreach item=data from=$arrStatusList}
  <tr bgcolor="#FFFFFF" onMouseOver="this.style.backgroundColor='#E9EDED';" onMouseOut="this.style.backgroundColor='#FFFFFF'"> 
    <td >&nbsp;{$data.createdTime}</td>
    <td >&nbsp;{$data.notified}</td>
    <td >&nbsp;{$data.status}</td>
    <td>&nbsp;{$data.comments|nl2br}</td>
  </tr>
  {/foreach}
</table>

<form name="form1" method="post" action="">
  <table width="100%" cellspacing="0" cellpadding="4">
    <tr> 
      <td colspan="3"><font color="#FF0000">&nbsp;{$error_message}</font></td>
    </tr>
    <tr> 
      <td width="100%" colspan="3" class="pageFrom">&nbsp;<b>Comments</b>:<textarea name="comments" wrap="soft" cols="60" rows="5"></textarea></td>
    </tr>
    <tr bgcolor="#FFFFFF"> 
      <td  width="20%" class="pageFrom"><b>Status:</b> 
      <select name="status">
      	<option value="pending">Pending</option>
      	<option value="processing" SELECTED>Processing</option>
      	<option value="delivered">Delivered</option>
      	<option value="packed">Packed</option>
      	<option value="returned">Returned</option>
      	<option value="canceled">Canceled</option>
      	<option value="shipped">Shipped</option>
      	
      </select></td>
      <td  width="20%" class="pageFrom"><b>Notify Customer:</b> <input type="checkbox" name="notify" CHECKED></td>
      <td  width="60%">
      <input type="submit" name="Submit" value="Update">
      <input name="id" type="hidden" id="menuid" value="{$id}">
      <input name="backurl" type="hidden" id="backurl" value="{$backurl}">
      </td>
    </tr>
</table>
</form>
  
	    </td>
      </tr>
</table>
</body>
</html>

